<template>
  <el-dialog
    title="设计器"
    width="90%"
    height="90%"
    :visible.sync="dialogVisible"
    @close="closeDialog"
  >
    <fm-making-form
      ref="makingform"
      style="height: 500px"
      :basic-fields="basicFields"
      :advance-fields="['imgupload']"
      :layout-fields="[]"
    >
      <template slot="action">
        <el-button type="text" icon="el-icon-upload">保存</el-button>
      </template>
    </fm-making-form>
  </el-dialog>
</template>

<script>
export default {
  name: 'FMDesigner',
  data() {
    return {
      dialogVisible: true,
      basicFields: [
        'input',
        'textarea',
        'number',
        'radio',
        'checkbox',
        'time',
        'date',
        'rate',
        'color',
        'select',
        'switch'
      ],
    };
  },
  methods: {
    closeDialog() {
      this.$emit('closeDialog');
    }
  }
};
</script>

<style></style>
